package ke01.pm;

import java.util.Date;

public class GeneratedMensch implements Interface {

	private String Name;
	private Date geburtsDatum;
	private int alter;

	/**
	 * @param name
	 * @param geburtsDatum
	 * @param alter
	 */
	public GeneratedMensch(String name, Date geburtsDatum, int alter) {
		this.Name = name;
		this.geburtsDatum = geburtsDatum;
		this.alter = alter;
	}

	public void setName(String name) {
		this.Name = name;
	}

	public String getName() {
		return Name;
	}

	public Date getGeburtsDatum() {
		return geburtsDatum;
	}

	@Override
	public String toString() {
		return "Mensch [name=" + Name + ", geburtsDatum=" + geburtsDatum
				+ ", alter=" + alter + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((geburtsDatum == null) ? 0 : geburtsDatum.hashCode());
		result = prime * result + ((Name == null) ? 0 : Name.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		GeneratedMensch other = (GeneratedMensch) obj;
		if (geburtsDatum == null) {
			if (other.geburtsDatum != null)
				return false;
		} else if (!geburtsDatum.equals(other.geburtsDatum))
			return false;
		if (Name == null) {
			if (other.Name != null)
				return false;
		} else if (!Name.equals(other.Name))
			return false;
		return true;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see ke01.pm.Interface#doSomething()
	 */
	@Override
	public void doSomething() {
		// TODO Auto-generated method stub

	}

	public static void main(String[] args) {
		System.out.println("Hallo");
	}
}
